<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta content="text/html; charset=UTF-8" http-equiv="content-type" />
<title> 礼品卡购买 - <?=SITE_NAME?> </title>

<?php include VIEWS.'header.html'?>

<script type="text/javascript">var totalprice = <?php echo intval($shopcar['totalprice'])?>;</script>
</head>
<body>

<?php include VIEWS.'validation.html'?>
<?php include VIEWS.'topbar.html'?>

<div id="content">

    <?php include VIEWS.'leftnav.html'?>

    <div id="right">

    <h1>乐铺礼品卡: 订购</h1>
    <?php do_action('view_checkout_gc_msg'); ?>

<?php if($code['checkout'] == 1):
    do_action('view_shopcar_checkout_gc_success', array('id'=>$indentid));
?>
	<meta http-equiv="refresh" content="0;url=/pay.php/<?php echo $indentid?>/gift" />
    <div class="goodbox roundNormal">&nbsp;&nbsp;&nbsp;礼品卡生成完毕，<a href="/pay.php/<?php echo $indentid?>/gift">点击这里进行付款</a></div>
<?php else:?>

<div style="width:100%;text-align:center"><img src="/images/giftcard/b<?=rand(1,3)?>.jpg" alt="" /></div>

<?php if($code['checkout'] & 4):?><div class="errbox roundNormal" style="width:90%">&nbsp;&nbsp;&nbsp;为保证物品能及时快捷的到达您的手中，请填写完整您的收货信息，谢谢!</div><?php endif?>

<hr size="1" />

<form action="/checkout.php/gift" id="checkoutform" method="post">
    
<div id="gcinfo">
<h3><img src="/images/icon_arrow_down.gif" />礼品卡</h3>
<table width="90%" cellpadding="5" align="center">
    <tr><td nowrap="nowrap" width="20%">礼品卡金额</td><td>
        <select name="iid">
            <option value="808">&yen; 20</option>
            <option value="829">&yen; 30</option>
            <option value="809" selected>&yen; 50</option>
            <option value="810">&yen; 80</option>
            <option value="811">&yen; 100</option>
            <option value="812">&yen; 150</option>
            <option value="813">&yen; 200</option>
            <option value="814">&yen; 300</option>
            <option value="815">&yen; 500</option>
        </select>
        <span class="px12">&nbsp; (单位：人民币)</span>
    </td></tr>
    <tr><td>接收人 <font color="red">*</font> </td><td nowrap="nowrap"><input title="谁是接收您礼品的幸运儿呢?" class="input1 required" id="linkman" type="text" name="linkman" maxlength="30" size="12" value="<?php echo $data['linkman']?>" /></td></tr>
    <tr><td>Email 地址 <font color="red">*</font> </td><td nowrap="nowrap"><input title="请正确填写接收人的邮件地址" style="padding-right:.5em" class="input1 required validate-email" id="remail" type="text" name="remail" maxlength="60" size="12" value="<?php echo $data['remail']?>" /></td></tr>
</table>
</div>

<hr size="1" />

<div id="gcinfo_ext">
<h3><img src="/images/icon_arrow_down.gif" />附加信息</h3>
<table width="90%" cellpadding="5" align="center">
    <!--
    <tr><td>发送方式 </td><td nowrap="nowrap">
            <input type="radio" checked="true" value="email" name="sendtype" />通过 Email
            <input type="radio" value="airmail" name="sendtype" />通过信函
    </td></tr>
    -->
    <tr><td>Email 发送?</td><td nowrap="nowrap">
        <div style="float:left"><input type="checkbox" checked="true" value="1" name="esend" /></div>
        <div class="px12" style="float:left;margin-left:10px;">选中此项，我们将会按照选定的日期通过 email 将该礼品卡<br />发送到接收人的邮箱中。<a href="/edm/giftcard/mail.php" target="_blank" onclick="javascript:window.open('/edm/giftcard/mail.php', 'loopo_edm_gc', 'width=640,height=600,scrollbars=yes');return false;">查看示例邮件</a></div>
    </td></tr>
    <tr><td>发送日期 <td nowrap="nowrap">
            <select name="y"><?php $Y=date('Y');for($i=$Y;$i<=$Y+1;$i++):?><option value="<?=$i?>"><?=$i?></option><?php endfor;?></select> 年
            <select name="m"><?php $M=date('m');for($i=1;$i<=12;$i++):?><option value="<?=$i?>"<?php echo $i==$M ? ' selected' : ''?>><?=$i?></option><?php endfor;?></select> 月
            <select name="d"><?php $D=date('d');for($i=1;$i<=31;$i++):?><option value="<?=$i?>"<?php echo $i==$D ? ' selected' : ''?>><?=$i?></option><?php endfor;?></select> 月
    </td></tr>
    <tr><td width="20%">想说的话 </td><td nowrap="nowrap"><textarea name="memo" rows="5" cols="40"><?php echo $data['memo']?></textarea>
        <div class="px12">&nbsp; <img src="/images/icon/icon_gift_small.gif" alt="Gift icon" align="absmiddle" /> 还有什么话想对她(他)说的吗？我们会一起将这些话发送哦。</div>
    </td></tr>
</table>
</div>

<hr size="1" />

<script type="text/javascript">new Validation('checkoutform',{useTitles:true,stopOnFirst:true});</script>

<?php if($data['linkman'] || $data['tel'] || $data['address'] || $data['zipcode']):?><script type="text/javascript">try{$('choiseaddress', 'newaddress').invoke('toggle')} catch(e){}</script><?php endif?>

<div id="contactinfo">
<h3><img src="/images/icon_arrow_down.gif" />联系人信息</h3>
<table width="90%" cellpadding="5" align="center">
    <tr><td nowrap="nowrap" width="20%">联系人 <font color="red">*</font> </td><td nowrap="nowrap"><input title="请填写联系人" class="input1 required" id="cman" type="text" name="cman" maxlength="30" size="12" value="<?php echo $data['cman']?>" /></td><td rowspan="3" class="px12 l16" style="padding-left:10px;border-left:1px solid #CCC"><b>乐铺提示</b>：该信息不同于接收人信息。<br />当礼品卡有问题的时候我们将通过这里的联系方式与您取得联系。<br /><br />礼品卡发送后，会同时通知到您的 Email 地址。</td></tr>
    <tr><td>联系电话 <font color="red">*</font> </td><td nowrap="nowrap"><input title="请填写联系人电话" style="padding-right:.5em" class="input1 required" id="cphone" type="text" name="cphone" maxlength="20" size="12" value="<?php echo $data['cphone']?>" /></td></tr>
    <tr><td>联系 Email <font color="red">*</font> </td><td nowrap="nowrap"><input title="请正确填写联系人邮件" style="padding-right:.5em" class="input1 required validate-email" id="cemail" type="text" name="cemail" maxlength="60" size="12" value="<?php echo $data['cemail']?$data['cemail']:$session['email']?>" /></td></tr>
</table>
</div>

<br />

<hr size="1" />
<center><input class="bluebtn" type="submit" style="font-weight:bold" value="下一步，付款" /></center>
</form>

<?php endif?>

    </div>
</div>

<?php include VIEWS.'copyright.html'?>

<!-- $Id: checkout_gc.html 26 2009-05-07 02:41:32Z bole.Chen $ -->
</body>
</html>
